{% extends 'base.html' %}
{% load static %}
{% load blog_tags %}
{% block right %}
<aside class="sidebar">
    <div class="widget widget_text">
        <div class="textwidget">
            <div class="social">

                <a href="https://weibo.com/cuiqingcai" rel="external nofollow" title="新浪微博" target="_blank"><i class="sinaweibo fa fa-weibo"></i></a>
                <a  href="http://t.qq.com/CQCcqc123456?preview" rel="external nofollow" title="腾讯微博" target="_blank"><i class="tencentweibo fa fa-tencent-weibo"></i></a>
                <a class="weixin"><i class="weixins fa fa-weixin"></i>
                    <div class="weixin-popover">
                        <div class="popover bottom in">
                            <div class="arrow"></div>
                            <div class="popover-title"></div>
                            <div class="popover-content"><img src="../static/images/weixin.gif" ></div>
                        </div>
                    </div>
                </a>
                <a href="http://mail.qq.com/cgi-bin/qm_share?t=qm_mailme&email=cqc@cuiqingcai.com" rel="external nofollow" title="Email" target="_blank"><i class="email fa fa-envelope-o"></i></a>
                <a href="/feed/" rel="external nofollow" target="_blank" title="订阅本站"><i class="rss fa fa-rss"></i></a>
            </div>
        </div>
    </div>

    <div class="widget widget_metaslider_widget">
        <!-- 热门专题-->
        <div class="title"><h2>热门专题</h2></div><!-- meta slider -->
        <div style="width: 100%;" class="metaslider metaslider-nivo metaslider-2698 ml-slider meta-slider">
            <div id="metaslider_container_2698">
                <div class='slider-wrapper theme-bar'>
                    <div class='ribbon'></div>
                    <div id='metaslider_2698' class='nivoSlider'>
                        {% get_carousel_right as carousels %}
                        {% for carousel in carousels %}
                        <a href="{{ carousel.url }}" target="_blank">
                            <img src="{{ carousel.img_url }}" height="300" width="320" data-title="{{ carousel.content }}" title="{{ carousel.title }}" alt="{{ carousel.title }}" class="slider-2698 slide-1720" />
                        </a>
                        {% endfor %}

                    </div>
                </div>
            </div>
            <!--热门专题结束 -->

            <script type="text/javascript">
                var metaslider_2698 = function($) {
                    $('#metaslider_2698').nivoSlider({
                        boxCols:7,
                        boxRows:5,
                        pauseTime:3000,
                        effect:"random",
                        controlNav:false,
                        directionNav:true,
                        pauseOnHover:true,
                        animSpeed:600,
                        prevText:"&lt;",
                        nextText:"&gt;",
                        slices:15,
                        manualAdvance:false
                    });
                };
                var timer_metaslider_2698 = function() {
                    var slider = !window.jQuery ? window.setTimeout(timer_metaslider_2698, 100) : !jQuery.isReady ? window.setTimeout(timer_metaslider_2698, 1) : metaslider_2698(window.jQuery);
                };
                timer_metaslider_2698();
            </script>
        </div>
    </div>
<!--// meta slider-->
    <div class="widget widget_text">
        <div class="textwidget"><p><a href="https://1024dada.com/?channel=cuiqingcai&#038;hmsr=%E5%B4%94%E5%BA%86%E6%89%8D&#038;hmpl=&#038;hmcu=&#038;hmkw=&#038;hmci="><img style="width: 100%;" src="/static/images/timͼƭ20181112165556.jpg" /><br />
</a></p></div>
    </div>
    <div class="widget widget_text">
        <div class="textwidget">
            <a href="https://developer.huaweicloud.com/campus?utm_source=cuiqingcai&utm_medium=blog&utm_campaign=campus"><img style="width:100%" src="/static/images/云服务器学生优惠套餐9元月.jpg"/></a>
        </div>
    </div>
    <!--文章归档 -->
    <div class="widget widget_archive">
        <div class="title"><h2>文章归档</h2></div>
        {% get_data_date as data_date %}
        <ul>
            {% if data_date %}
                {% for date in data_date %}
            <li><a href='{% url 'blog:date' date|date:'Y' date|date:'m' %}'>{{ date|date:'Y-m' }}</a></li>
                {% endfor %}
            {% else %}
                <div>近期没有发表过文章</div>
            {% endif %}
        </ul>
    </div>
    <!--文章归档结束 -->
    <!--猜你喜欢 -->
    <div class="widget d_postlist">
        <div class="title"><h2>猜你喜欢</h2></div>
        <ul>
            {%  get_article_list 'loves' 6 as hot_tag %}
            {% for hot in hot_tag %}
            <li>
                <a href="/article/{{ hot.slug }}" title="{{ hot.title }}" >
                <span class="thumbnail">
                <img src="{{ hot.img_link }}" alt="{{ hot.title }}" />
                </span>
                <span class="text">{{ hot.title }}</span>
                <span class="muted">{{ hot.create_date|date:'Y-m-d' }}</span>
                <span class="muted">{{ hot.loves }}喜欢</span>
                </a>
            </li>

            {% endfor %}
        </ul>
    </div>
    <!--猜你喜欢结束 -->
    <!--标签云 -->
    <div class="widget d_tag">
        <div class="title"><h2>标签云</h2></div>
        <div class="d_tags">
            {% get_tag_list as tags %}
            {% for tag in tags %}

            <!--tag.total_num直接获得标签次标签下的文章数 -->
            <a title="{{ tag.total_num }}个话题" href="{% url 'blog:tag' tag.name %}">{{ tag.name }}({{ tag.total_num }})</a>
            {% endfor %}

        </div>
    </div>
    <!--标签云结束-->

    <!--友情链接 -->
    <div class="widget widget_links">
        <div class="title"><h2>友情链接</h2></div>
            {% get_friends as friends %}
            <ul class='xoxo blogroll'>
                {% if friends %}
                    {% for friend in friends %}
                <li><a href="http://www.99banzou.com" target="_blank">99伴奏网</a></li>
                    {% endfor %}
                {% else %}
                    <div>&nbsp;&nbsp;暂无友链，欢迎来战</div>
                {% endif %}
            </ul>
    </div>
    <!--友情链接结束 -->
    <div class="widget widget_text">
        <div class="title"><h2>精品推荐</h2></div>
        <div class="textwidget">
            <div class="side-ad">
                <script type="text/javascript">
                            var cpro_id="u2578794";
            (window["cproStyleApi"] = window["cproStyleApi"] || {})[cpro_id]={at:"3",rsi0:"300",rsi1:"250",pat:"17",tn:"baiduCustNativeAD",rss1:"#FFFFFF",conBW:"1",adp:"1",ptt:"0",titFF:"%E5%BE%AE%E8%BD%AF%E9%9B%85%E9%BB%91",titFS:"14",rss2:"#00a67c",titSU:"0"}
                </script>
                <script src="../static/js/c.js" type="text/javascript"></script>
            </div>
            <style>
                #BAIDU_SSP__wrapper_u2578794_1 {
                display:none;
                }
                #BAIDU_SSP__wrapper_u2578794_0 #iframeu2578794_0  .bd-logo2 {
                display:none !important;
                }
            </style>
        </div>
    </div>
    <div class="widget widget_text">
        <div class="title"><h2>新浪微博</h2></div>
        <div class="textwidget">
            <iframe width="100%" class="share_self"  frameborder="0" scrolling="no" src="https://widget.weibo.com/weiboshow/index.php?language=&width=0&height=550&fansRow=2&ptype=1&speed=0&skin=1&isTitle=0&noborder=0&isWeibo=1&isFans=1&uid=2830678474&verifier=7468dc7b&dpc=1">

            </iframe>
        </div>
    </div>
    <div class="widget widget_text">
        <div class="textwidget">
            <a href="https://edu.hellobi.com/course/157" style="display:none"><img src="../static/images/wx20180104-140302.png"/></a>
        </div>
    </div>
</aside>
{% endblock %}